package hoowin.app.wsnd.action;

import hoowin.app.wsnd.model.Status;
import hoowin.app.wsnd.service.StatusService;
import hoowin.basic.model.User;

import com.opensymphony.xwork2.ActionSupport;

@SuppressWarnings("serial")
public class GetDiscussions extends ActionSupport {
	private int statusId;
	private StatusService statusService;
	private User user;
	private Status status;
	public String execute(){
		if(statusId==0 || user.getId()==0)return SUCCESS;
		status = statusService.getStatusWithDiscussions(statusId);
		return SUCCESS;	
	}
	public void setStatusId(int statusId) {
		this.statusId = statusId;
	}
	public int getStatusId() {
		return statusId;
	}
	public void setUser(User user) {
		this.user = user;
	}
	public User getUser() {
		return user;
	}
	public void setStatus(Status status) {
		this.status = status;
	}
	public Status getStatus() {
		return status;
	}
	public void setStatusService(StatusService statusService) {
		this.statusService = statusService;
	}
	public StatusService getStatusService() {
		return statusService;
	}
}
